<include file="../Public/agent.header.html" />
<!--表单验证-->
<script type="text/javascript" src="__PUBLIC__/Js/jquery.validator.reg.js"></script>
<script type="text/javascript" src="__PUBLIC__/Js/jquery.corners.min.js"></script>
<link href="__PUBLIC__/Js/form_check/type.css" rel="stylesheet" type="text/css" />
<script>
$(function(){
	$('#loginForm').checkForm();
	$("#new_joins").find("#card").hover(
	        function(){
	        	ui.card(this);
	        },
	        function(){
	        	//$('#q_ui_card').fadeOut("fast");
	        }
 	);
});
function canDoFormSubmit(formid){
	var form=$('#'+formid);
	var elements = form.find(':input[require]');
	elements.blur(function(index){
		return validator.check(jQuery(this));
	});
	var isValid = true;
	var errIndex= new Array();
	var n=0;
	elements.each(function(i){
		if(validator.check(jQuery(this))==false){
			isValid  = false;
			errIndex[n++]=i;
		};
	});

	if(isValid==false){
		elements.eq(errIndex[0]).focus().select();
		return false;
	}

	return true;
}


function doFormLoginSubmit(formid){
	var result = canDoFormSubmit(formid);

	if(result){
		//$('#show_logining').show();
		//$('#quick_login_area').hide();
		$.kajax({      
			ajx_rtn_type:'JSON',
			url:$('#'+formid).attr('action'),      
			type:'post',
			data:{ 	email:$('#'+formid).find("input@[name='login_email']").val()
					,password:$('#'+formid).find("input@[name='login_password']").val()
					,verify:$('#'+formid).find("input@[name='login_verify']").val()} ,    
			//async: false ,
			success: function(obj){
				//alert(obj);
				if(obj.status==1){
					ui.success('登陆成功！');
					k_page_redirect( '{:U('agent://Account/index')}' );
				}else{
					ui.error(obj.msg);
					if(obj.redirect!=null){
						k_page_redirect( obj.redirect );
					}
					//$('#show_logining').hide();
					//$('#quick_login_area').show();
				}
			}
		});
	}
}
</script>
	<div class="blank10"></div>
	
    <div class="contentArea">
        <!--   S 内容左侧   -->
        <div class="contentA">
            <div id="loginContainer">
            <!--   登录前   -->
            <form action="{:U('agent://Public/doLogin')}" method="post" id="loginForm">
            	<div class="loginArea">
	            	<h2 class="loginHead">联盟会员登录</h2>
	            	
	            	<span class="blank20"></span>
	            	<div class="FTextArea">
	            		<span>邮箱：</span>
	            		<input id="login_email" name="login_email" class="FText01" type="text" 
	            		 					require="true" datatype="limit|email" min="1" msg="不能为空|格式错误"/>
	            	</div>
	            	<span class="blank20" style="font-size: 12px;">
	            		<div class="error_login_email" style="position: relative;display:none;color: red; padding-right: 20px; text-align: right;">
		            		<span class="ico_cue_no"></span><span id="error_login_email"></span>
		            	</div>
		            </span>
	            	
	            	<div class="FTextArea">
	            		<span>密码：</span>	            		
	            		<input type="password" class="FText01" 
		        					name="login_password" id="login_password" require="true" value="" datatype="limit"  min="6" max="16" msg="长度6-16"/>       
		        	</div>
		        	<span class="blank20" style="font-size: 12px;">
		            	<div class="error_login_password" style="position: relative;display:none;color: red; padding-right: 20px; text-align: right;"> 
		            		<span class="ico_cue_no"></span><span id="error_login_password"></span>
						</div>
	            	</span>
	            	
	            	<div class="FTextArea">
	            		<span>验证码：</span>
	            		<input type="text" class="FText02" 
		        			name="login_verify" require="true" value="" datatype="require" msg="输入验证码"/>
	            		<div class="yanzhengArea">
	            			<img onclick="changeverify()" style="cursor: pointer;vertical-align: middle;" id="verifyimg" alt="看不清？请点击！" 
			       				src="{:U('Index://Public/verify')}">
			       			<a class="forget" href="javascript:void(0);" onclick="changeverify()" style="cursor: pointer;">刷新</a>
	            		</div>
	            	</div>
	            	<span class="blank20" style="font-size: 12px;">
						<div id="success_login_verify"  style="display:none;"> <span class="ico_cue_ok"></span> </div>
			       		<div class="r error_login_verify" style="position: relative;display:none;color: red; padding-right: 20px; text-align: right;"> 
			       		<span class="ico_cue_no"></span><span id="error_login_verify"></span> </div>
	            	</span>
	            	<div class="FTextArea">
	            		<input value="登 录" class="FloginBtn" type="button" onclick="doFormLoginSubmit('loginForm')">
	            		<span><a target="_blank" href="{:U('agent://Public/sendPassword')}">密码忘记了？</a></span>
	            	</div>
	            	<span class="blank20"></span>
	            	<div>
	            		<input value="免费快速注册" class="regBtn" onclick="window.location.href='{:U('agent://Public/register')}'" type="button">
	            	</div>
	            	<span class="blank15"></span>
	            	<span class="blank15"></span>
            	</div>
            </form>
            </div>
			<span class="blank15"></span>
            <!--bom-->
            <div class="newJoinArea" id='new_joins'>
          		<h2 class="loginHead">最新加入会员</h2>
             	<span class="blank20"></span>
              	<volist id="vo" name="new_agents">
                	<div class="joinList">
                   		<span>{:paramMillisecond2Date($vo['ctime'],'m月d日','-- --')}</span>
                      	<h2><strong>{$i}</strong></h2>
                     	<p><font id="card" rel="card" 
                     		uid="{$vo['user_id']}" curl="{:U('agent://Index/agentcard')}" >{$vo['title']|escape}</font></p>
                  	</div><span class="blank15"></span>
              	</volist>
              	<span class="blank5"></span>
         	</div>
        </div>
        <!--   E 内容左侧   -->
        <!--   S 内容右侧   -->
        <div class="contentB">
            <div class="banner01">
                <img src="__PUBLIC__/Images/agent/agent_banner.jpg" alt=""></div>
            <span class="blank15"></span>
            <div class="hezuoArea">
                <ul>
                    <li style="width: 370px;"><span class="blank12"></span>
                        <h2>网站、博客合作</h2>
                        <span class="blank15"></span>
                        <p>
							只要您有自己的网站和博客，注册成为小心意网站联盟会员后，就可以将获得的插件代码粘贴在您的网站的任意位置，实现每月轻松赚取高分成收益。</p>
                        <div class="hezuoBtnIndex"><a href="{:U('agent://Index/help',array('sortcode'=>'doc_agent_site'))}">了解更多</a></div>
                    </li>
                    <li style="width: 371px;"><span class="blank12"></span>
                        <h2>网店代销合作</h2>
                        <span class="blank15"></span>
                        <p>
							 如果您有自己的网上店铺，注册成为小心意网站联盟会员后，就可以在您的店铺中代送小心意提供的礼品，或是将获得的插件代码粘贴在您的网店页面中、或是利用“我的联盟中心”->“代客送礼”功能来下单，轻松增加店铺分成收益。</p>
                        <div class="hezuoBtnIndex"><a href="{:U('agent://Index/help',array('sortcode'=>'doc_agent_eshop'))}">了解更多</a></div>
                    </li>
                </ul>
            </div>
        </div>
        <!--   E 内容右侧   -->
    </div>
    <span class="blank15"></span>
    <!--bom--><!--   S 标准尾   -->
                        <div class="serviceArea">
	                         <span class="blank25"></span>
                               <div class="serivceLeft">
	                              <h2>小心意联盟优势</h2>
		                            <span class="blank25"></span>
		                            <ul>
		                             <li>商品信息及时、准确；</li>
		                             <li>人员专业，联盟运作经验丰富，行业口碑好，值得信赖；</li>
		                             <li>免费注册，免费加盟，收益分成比例高；</li>
		                             <li>订单记录准确、实时、公正、按时支付不拖欠； </li>
		                            </ul>
	                             </div>
	                             <div class="serivceCenter">
	                              <h2><a href="{:U('agent://Index/help',array('sortcode'=>'doc_agent_site'))}" target="_blank" style="font-size: 16px; color: #494949;">常见问题</a></h2>
		                            <span class="blank25"></span>
		                            <ul>
		                            	<li><a href="{:U('agent://Index/help',array('sortcode'=>'doc_agent_site'))}" target="_blank">网站加盟及合作步骤</a></li>
		                            	<li><a href="{:U('agent://Index/help',array('sortcode'=>'doc_agent_blog'))}" target="_blank">博客加盟及合作步骤</a></li>
		                            	<li><a href="{:U('agent://Index/help',array('sortcode'=>'doc_agent_eshop'))}" target="_blank">网店加盟及合作步骤</a></li>
		                            	<li><a href="{:U('agent://Index/help',array('sortcode'=>'doc_agent_rebate'))}" target="_blank">加盟收益如何计算？</a></li>
		                            </ul>
	                             </div>
	                             <div class="serivceRight">
	                              <h2>联系方式</h2>
		                            <span class="blank25"></span>
		                            <ul>
		                             <li>售后电话：<strong>010-52878545</strong></li>
		                             <li>联盟Email：union@xiaoxinyi.com</li>
		                            </ul>
	                             </div>
	                             <span class="blank25"></span>
	                             <span class="blank10"></span>
	                            </div>
                          <!--   E 标准尾   -->
                    

<include file="../Public/footer.html" />